package loader
{
	import flash.events.Event;
	import flash.net.URLLoader;
	import flash.net.URLLoaderDataFormat;
	import flash.net.URLRequest;

	public class TempLoader
	{
		
		public var bonesData:Object;
		public var resData:Object;
		
		public function TempLoader()
		{
			
		}
		
		public function loadRes(name:String,url:String):void
		{
			var resLoader:URLLoader = new URLLoader();
			resLoader.dataFormat = URLLoaderDataFormat.BINARY;
			resLoader.addEventListener(Event.COMPLETE,resLoadComplete);
			resLoader.load(new URLRequest(url));
		}
		
		public function loadBones(name:String,url:String):void
		{
			var boneLoader:URLLoader = new URLLoader();
			boneLoader.dataFormat = URLLoaderDataFormat.BINARY;
			boneLoader.addEventListener(Event.COMPLETE,bonesLoadComplete);
			boneLoader.load(new URLRequest(url));
		}
		
		private function resLoadComplete(e:Event):void
		{
			resEata = e.target.data;
		}
		
		private function bonesLoadComplete(e:Event):void
		{
			bonesData = e.target.data;
		}
	}
}